import React from 'react'
import { Space, Table, Button, Modal, Form, Input, DatePicker } from 'antd';

export default function Order() {

  //表格
  const columns = [
    {
      title: '商品ID',
      dataIndex: 'id',
      key: 'id',
    },
    {
      title: '买家ID',
      dataIndex: 'userId',
      key: 'userId',
    },
    {
      title: '销量',
      dataIndex: 'sales',
      key: 'sales',
    },
    {
      title: '时间',
      key: 'time',
      dataIndex: 'time',
    },
    {
      title: '单价',
      key: 'price',
      dataIndex: 'price',
    },
    {
      title: '订单状态',
      dataIndex: 'status',
      key: 'status',
    },
    {
      title: '操作',
      key: 'action',
      render: (_, record) => (
        <Space size="middle">
          <Button>编辑</Button>
          <Button type="primary" danger >
            删除
          </Button>
        </Space>
      ),
    },
  ];

  //表格数据
  const data = [
    {
      id: '1',
      userId:'01',
      sales: '100',
      time: '2024-01-01',
      price: '11',
      status: '已送达',
    },
  ];

  return (
    <>
      <Table columns={columns} dataSource={data} />
    </>
  )
}
